]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
dateMenu: Set _delegate on non-menu-item menu child
authorFlorian Müllner <fmuellner@gnome.org>
Sat, 17 Jun 2017 16:14:20 +0000 (18:14 +0200)
committerFlorian Müllner <fmuellner@gnome.org>
Thu, 13 Jul 2017 15:23:54 +0000 (17:23 +0200)
PopupMenu needs special-treatment of certain types of menu items,
which it determines via children's _delegate property. However as
the calendar drop-down is very unmenu-ish, we use regular actors
rather than PopupMenuItems and the missing _delegate property
triggers a warning. Just add it as the bare minimum to make
PopupMenu happy.

https://bugzilla.gnome.org/show_bug.cgi?id=781471

js/ui/dateMenu.js

index 1ce377936cf99873878710b74f10cddd0c36ea81..f891ae3c256259c5b300ad8b59f929f065231523 100644 (file)
@@ -474,6 +474,8 @@ const DateMenuButton = new Lang.Class({
 
         let layout = new FreezableBinLayout();
         let bin = new St.Widget({ layout_manager: layout });
+        // For some minimal compatibility with PopupMenuItem
+        bin._delegate = this;
         this.menu.box.add_child(bin);
 
         hbox = new St.BoxLayout({ name: 'calendarArea' });